# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=mauikit-accounts
pkgver=2.1.2
pkgrel=0
pkgdesc="MauiKit Utilities to handle User Accounts"
# armhf blocked by extra-cmake-modules
# s390x and riscv64 blocked by mauikit
arch="all !armhf !s390x !riscv64"
url="https://mauikit.org/"
license="GPL-2.0-or-later"
depends="
	kirigami2
	"
depends_dev="
	kconfig-dev
	kcoreaddons-dev
	ki18n-dev
	mauikit-dev
	qt5-qtbase-dev
	qt5-qtdeclarative-dev
	"
makedepends="$depends_dev
	extra-cmake-modules
	samurai
	"
source="https://download.kde.org/stable/maui/mauikit-accounts/$pkgver/mauikit-accounts-$pkgver.tar.xz"
subpackages="$pkgname-dev"

build() {
	cmake -B build -G Ninja \
		-DCMAKE_BUILD_TYPE=RelWithDebInfo \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib
	cmake --build build
}

check() {
	cd build
	CTEST_OUTPUT_ON_FAILURE=TRUE ctest
}

package() {
	DESTDIR="$pkgdir" cmake --install build
}

sha512sums="
bdd94d442a15536af7618c2440a6235e71d3c663bec6a7471fcafdddc2884dbc61070a6e39dd7daafd59ede2b1c6613efa06065ac6dab96f9a456b81df24fe28  mauikit-accounts-2.1.2.tar.xz
"
